<html>
<head>
<title>Mywiki > <%= request.path_parameters['action'] %></title>
<%= javascript_include_tag "prototype" %>
  <%= yield :tinymce %>
  <%= javascript_include_tag "scriptaculous" %> 
  <%= javascript_include_tag "effects" %> 
  <%= javascript_include_tag "controls" %>
  <%= yield :tinymce_init %> 
<style type="text/css" media=screen>
  body {
    font-family: verdana, courier, serif
  }

  table.mywikiview {
	border-width: thin;
	border-spacing: 1px ;
	border-style: hidden;
	border-color: orange;
	border-collapse: separate;
	background-color: white;
  }
  table.mywikiview th {
	border-width: 1px;
	padding: 2px;
	border-style: outset;
	border-color: orange;
	background-color: rgb(255, 250, 250);
	-moz-border-radius: ;
  }
  table.mywikiview td {
	border-width: 1px;
	padding: 2px;
	border-style: outset;
	border-color: orange;
	background-color: rgb(255, 250, 250);
	-moz-border-radius: ;
  }
 </style>
</head>

<link href="/stylesheets/mywikis.css" rel="stylesheet" type="text/css" />
<body>
<table width="100%" height="100%" cellpadding="0" cellspacing="0" border="1">
<tr>
<td valign="top" width="150">
<center>
<img height="100" width="100" src="/images/sjsu.jpg" />
<hr>
<% if @puser != false %>
<b>User: <%= @user['user'] %></b><br>
<a href = "/mywiki/logout"><b>logout</b></a>
<% end %>
<p>
<% if @search == false
      #noop
   else
%>   

  <%= form_tag('/mywiki/search') %>
  <%= text_field_tag 'searchkey', 'keywords', :size => 10, :maxlength => 25 %>
  <br>
  <%= submit_tag 'Search' %>
  <% $end %>
<% end %>
</center>
<% if @recent.nil? 
	#noop
   else %>      
  <p>Recent updates:<br>
<% for mywiki in @recent %>
	<%= link_to mywiki.title, :controller => 'mywiki', :action => 'view', :f => mywiki.title %><br>
<% end %>
<% end %>


</td>
<td valign="top" >
<table width="100%" cellpadding="10" cellspacing="0" border="1">
    <tr class="pageheader" valign="middle">
        <td align="left">
            <%= link_to 'home', :controller => 'mywiki', :action => 'index' %> |
			<% if @page.nil?
			   #noop
			   else %>
			<%= link_to 'new', :controller => 'mywiki', :action => 'new' %> |
			<% end %>
			<% if @view.nil? 
			     #noop
			   else %>
			     <%= link_to 'edit', :controller => 'mywiki', :action => 'edit', :f => @filename %> |
				 <%= link_to 'delete', :controller => 'mywiki', :action => 'destroy', :id => @fileid %> |
				 <%= link_to 'new', :controller => 'mywiki', :action => 'new' %> |
			<% end %>			
			<% if @manage == true %>
				<%= link_to 'manage', :controller => 'mywiki_user', :action => 'manage' %> |
			<% end %>
            <%= link_to 'help', :controller => 'mywiki', :action => 'help', :f => @filename %>
        </td>
        <td align="right">
            <strong>Mywiki > <%= request.path_parameters['action'] %> > <%= @filename %></strong>
        </td>
  </tr>

    <tr>
      <td align="left" colspan="2">
			<p style="color: green"><%= flash[:notice] %></p>
			<p style="color: red"><%= flash[:error] %></p>
            <%= yield :layout %>
      </td>
    </tr>

    <tr class="pagefooter">
        <td align="left" valign="MIDDLE">
            <% if @filestat.nil? %>
                &nbsp;
            <% else %>
                <%= @filestat.strftime("Created on: %a, %d %b, %Y at %H:%M:%S") %>                 
            <% end %>
        </td>
      <td align="right" valign="MIDDLE"><%= Time.now.strftime("Generated on: %a, %d %b, %Y at %H:%M:%S") %>&nbsp;</td>
    </tr>
</table>
</td>
</tr>
</table>
</body>
</html>
